package io.dbw.modules.business.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

import javax.validation.constraints.NotBlank;

/**
 *
 * @author lxc
 * @date 2024-03-30 16:55:49
 */
@Data
@TableName("sys_books")
@Api(tags = "图书管理")
public class SysBooksEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	@TableId
	@ApiModelProperty(value = "图书ID")
	private Long bookId;

	@ApiModelProperty(value = "书名")
	@NotBlank(message = "书名不能为空")
	private String bookName;

	@ApiModelProperty(value = "作者")
	private String bookAuthor;

	@ApiModelProperty(value = "出版社")
	private String bookPress;

	@ApiModelProperty(value = "发行年份")
	private String releasedDate;

	@ApiModelProperty(value = "库存")
	private Integer bookStock;

	@TableField(exist = false)
	@ApiModelProperty(value = "是否借该书,1:是,0:否")
	private Integer borrowFlag;

	@TableLogic
	@ApiModelProperty(value = "是否删除:Y:是;N:否")
	private String deleteFlag;

	@ApiModelProperty(value = "创建者ID",hidden = true)
	private Long createBy;

	@ApiModelProperty(value = "创建时间",hidden = true)
	private Date createTime;

	@ApiModelProperty(value = "修改人",hidden = true)
	private Long updateBy;

	@ApiModelProperty(value = "修改时间",hidden = true)
	private Date updateTime;


}
